home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1998 April: Mac OS SDK / Dev.CD Apr 98 SDK1.toast / Development Kits (Disc 1) / Interfaces&Libraries / Universal / Interfaces / PInterfaces / PPCToolbox.p < prev    next >
Encoding:
Text File  |  1998-02-12  |  18.7 KB  |  502 lines  |  [TEXT/MPS ]

  1. {
  2.      File:        PPCToolbox.p
  3.  
  4.      Contains:    Program-Program Communications Toolbox Interfaces.
  5.  
  6.      Version:    Technology:    System 7.5
  7.                  Release:    Universal Interfaces 3.1
  8.  
  9.      Copyright:    © 1989-1993, 1995-1998 by Apple Computer, Inc., all rights reserved
  10.  
  11.      Bugs?:        Please include the the file and version information (from above) with
  12.                  the problem description.  Developers belonging to one of the Apple
  13.                  developer programs can submit bug reports to:
  14.  
  15.                      devsupport@apple.com
  16.  
  17. }
  18. {$IFC UNDEFINED UsingIncludes}
  19. {$SETC UsingIncludes := 0}
  20. {$ENDC}
  21.  
  22. {$IFC NOT UsingIncludes}
  23.  UNIT PPCToolbox;
  24.  INTERFACE
  25. {$ENDC}
  26.  
  27. {$IFC UNDEFINED __PPCTOOLBOX__}
  28. {$SETC __PPCTOOLBOX__ := 1}
  29.  
  30. {$I+}
  31. {$SETC PPCToolboxIncludes := UsingIncludes}
  32. {$SETC UsingIncludes := 1}
  33.  
  34. {$IFC UNDEFINED __MACTYPES__}
  35. {$I MacTypes.p}
  36. {$ENDC}
  37. {$IFC UNDEFINED __APPLETALK__}
  38. {$I AppleTalk.p}
  39. {$ENDC}
  40.  
  41.  
  42. {$PUSH}
  43. {$ALIGN MAC68K}
  44. {$LibExport+}
  45.  
  46.  
  47. TYPE
  48.     PPCServiceType                        = UInt8;
  49.  
  50. CONST
  51.     ppcServiceRealTime            = 1;
  52.  
  53.  
  54. TYPE
  55.     PPCLocationKind                        = INTEGER;
  56.  
  57. CONST
  58.     ppcNoLocation                = 0;                            {  There is no PPCLocName  }
  59.     ppcNBPLocation                = 1;                            {  Use AppleTalk NBP       }
  60.     ppcNBPTypeLocation            = 2;                            {  Used for specifying a location name type during PPCOpen only  }
  61.  
  62.  
  63. TYPE
  64.     PPCPortKinds                        = INTEGER;
  65.  
  66. CONST
  67.     ppcByCreatorAndType            = 1;                            {  Port type is specified as colloquial Mac creator and type  }
  68.     ppcByString                    = 2;                            {  Port type is in pascal string format  }
  69.  
  70. { Values returned for request field in PPCInform call }
  71.  
  72. TYPE
  73.     PPCSessionOrigin                    = UInt8;
  74.  
  75. CONST
  76.                                                                 {  Values returned for requestType field in PPCInform call  }
  77.     ppcLocalOrigin                = 1;                            {  session originated from this machine  }
  78.     ppcRemoteOrigin                = 2;                            {  session originated from remote machine  }
  79.  
  80.  
  81. TYPE
  82.     PPCPortRefNum                        = INTEGER;
  83.     PPCSessRefNum                        = LONGINT;
  84.     PPCPortRecPtr = ^PPCPortRec;
  85.     PPCPortRec = RECORD
  86.         nameScript:                ScriptCode;                                {  script of name  }
  87.         name:                    Str32Field;                                {  name of port as seen in browser  }
  88.         portKindSelector:        PPCPortKinds;                            {  which variant  }
  89.         CASE INTEGER OF
  90.         0: (
  91.             portTypeStr:        Str32;                                    {  pascal type string  }
  92.             );
  93.         1: (
  94.             portCreator:        OSType;
  95.             portType:            OSType;
  96.            );
  97.     END;
  98.  
  99.     PPCPortPtr                            = ^PPCPortRec;
  100.     LocationNameRecPtr = ^LocationNameRec;
  101.     LocationNameRec = RECORD
  102.         locationKindSelector:    PPCLocationKind;                        {  which variant  }
  103.         CASE INTEGER OF
  104.         0: (
  105.             nbpEntity:            EntityName;                                {  NBP name entity  }
  106.             );
  107.         1: (
  108.             nbpType:            Str32;                                    {  just the NBP type string, for PPCOpen  }
  109.             );
  110.     END;
  111.  
  112.     LocationNamePtr                        = ^LocationNameRec;
  113.     PortInfoRecPtr = ^PortInfoRec;
  114.     PortInfoRec = RECORD
  115.         filler1:                SInt8;
  116.         authRequired:            BOOLEAN;
  117.         name:                    PPCPortRec;
  118.     END;
  119.  
  120.     PortInfoPtr                            = ^PortInfoRec;
  121.     PortInfoArrayPtr                    = ^PortInfoRec;
  122.     PPCParamBlockRecPtr = ^PPCParamBlockRec;
  123.     PPCParamBlockPtr                    = ^PPCParamBlockRec;
  124. {$IFC TYPED_FUNCTION_POINTERS}
  125.     PPCCompProcPtr = PROCEDURE(pb: PPCParamBlockPtr);
  126. {$ELSEC}
  127.     PPCCompProcPtr = ProcPtr;
  128. {$ENDC}
  129.  
  130.     PPCCompUPP = UniversalProcPtr;
  131.     PPCOpenPBRecPtr = ^PPCOpenPBRec;
  132.     PPCOpenPBRec = PACKED RECORD
  133.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  134.         csCode:                    UInt16;                                    {  Requested PPC command  }
  135.         intUse:                    UInt16;                                    {  Internal Use  }
  136.         intUsePtr:                Ptr;                                    {  Internal Use  }
  137.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  138.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  139.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  140.         portRefNum:                PPCPortRefNum;                            {  38 <--   Port Reference  }
  141.         filler1:                LONGINT;
  142.         serviceType:            PPCServiceType;                            {  44 -->    Bit field describing the requested port service  }
  143.         resFlag:                UInt8;                                    {  Must be set to 0  }
  144.         portName:                PPCPortPtr;                                {  46 -->   PortName for PPC  }
  145.         locationName:            LocationNamePtr;                        {  50 -->   If NBP Registration is required  }
  146.         networkVisible:            BOOLEAN;                                {  54 -->   make this network visible on network  }
  147.         nbpRegistered:            BOOLEAN;                                {  55 <--   The given location name was registered on the network  }
  148.     END;
  149.  
  150.     PPCOpenPBPtr                        = ^PPCOpenPBRec;
  151.     PPCInformPBRecPtr = ^PPCInformPBRec;
  152.     PPCInformPBRec = PACKED RECORD
  153.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  154.         csCode:                    UInt16;                                    {  Requested PPC command  }
  155.         intUse:                    UInt16;                                    {  Internal Use  }
  156.         intUsePtr:                Ptr;                                    {  Internal Use  }
  157.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  158.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  159.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  160.         portRefNum:                PPCPortRefNum;                            {  38 -->   Port Identifier  }
  161.         sessRefNum:                PPCSessRefNum;                            {  40 <--   Session Reference  }
  162.         serviceType:            PPCServiceType;                            {  44 <--   Status Flags for type of session, local, remote  }
  163.         autoAccept:                BOOLEAN;                                {  45 -->   if true session will be accepted automatically  }
  164.         portName:                PPCPortPtr;                                {  46 -->   Buffer for Source PPCPortRec  }
  165.         locationName:            LocationNamePtr;                        {  50 -->   Buffer for Source LocationNameRec  }
  166.         userName:                StringPtr;                                {  54 -->   Buffer for Soure user's name trying to link.  }
  167.         userData:                UInt32;                                    {  58 <--   value included in PPCStart's userData  }
  168.         requestType:            PPCSessionOrigin;                        {  62 <--   Local or Network  }
  169.         filler:                    SInt8;
  170.     END;
  171.  
  172.     PPCInformPBPtr                        = ^PPCInformPBRec;
  173.     PPCStartPBRecPtr = ^PPCStartPBRec;
  174.     PPCStartPBRec = PACKED RECORD
  175.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  176.         csCode:                    UInt16;                                    {  Requested PPC command  }
  177.         intUse:                    UInt16;                                    {  Internal Use  }
  178.         intUsePtr:                Ptr;                                    {  Internal Use  }
  179.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  180.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  181.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  182.         portRefNum:                PPCPortRefNum;                            {  38 -->   Port Identifier  }
  183.         sessRefNum:                PPCSessRefNum;                            {  40 <--   Session Reference  }
  184.         serviceType:            PPCServiceType;                            {  44 <--   Actual service method (realTime)  }
  185.         resFlag:                UInt8;                                    {  45 -->   Must be set to 0   }
  186.         portName:                PPCPortPtr;                                {  46 -->   Destination portName  }
  187.         locationName:            LocationNamePtr;                        {  50 -->   NBP or NAS style service location name  }
  188.         rejectInfo:                UInt32;                                    {  54 <--   reason for rejecting the session request  }
  189.         userData:                UInt32;                                    {  58 -->   Copied to destination PPCInform parameter block  }
  190.         userRefNum:                UInt32;                                    {  62 -->   userRefNum (obtained during login process)   }
  191.     END;
  192.  
  193.     PPCStartPBPtr                        = ^PPCStartPBRec;
  194.     PPCAcceptPBRecPtr = ^PPCAcceptPBRec;
  195.     PPCAcceptPBRec = RECORD
  196.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  197.         csCode:                    UInt16;                                    {  Requested PPC command  }
  198.         intUse:                    UInt16;                                    {  Internal Use  }
  199.         intUsePtr:                Ptr;                                    {  Internal Use  }
  200.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  201.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  202.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  203.         filler1:                INTEGER;
  204.         sessRefNum:                PPCSessRefNum;                            {  40 -->   Session Reference  }
  205.     END;
  206.  
  207.     PPCAcceptPBPtr                        = ^PPCAcceptPBRec;
  208.     PPCRejectPBRecPtr = ^PPCRejectPBRec;
  209.     PPCRejectPBRec = RECORD
  210.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  211.         csCode:                    UInt16;                                    {  Requested PPC command  }
  212.         intUse:                    UInt16;                                    {  Internal Use  }
  213.         intUsePtr:                Ptr;                                    {  Internal Use  }
  214.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  215.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  216.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  217.         filler1:                INTEGER;
  218.         sessRefNum:                PPCSessRefNum;                            {  40 -->   Session Reference  }
  219.         filler2:                INTEGER;
  220.         filler3:                LONGINT;
  221.         filler4:                LONGINT;
  222.         rejectInfo:                UInt32;                                    {  54 -->   reason for rejecting the session request   }
  223.     END;
  224.  
  225.     PPCRejectPBPtr                        = ^PPCRejectPBRec;
  226.     PPCWritePBRecPtr = ^PPCWritePBRec;
  227.     PPCWritePBRec = RECORD
  228.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  229.         csCode:                    UInt16;                                    {  Requested PPC command  }
  230.         intUse:                    UInt16;                                    {  Internal Use  }
  231.         intUsePtr:                Ptr;                                    {  Internal Use  }
  232.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  233.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  234.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  235.         filler1:                INTEGER;
  236.         sessRefNum:                PPCSessRefNum;                            {  40 -->   Session Reference  }
  237.         bufferLength:            Size;                                    {  44 -->   Length of the message buffer  }
  238.         actualLength:            Size;                                    {  48 <--   Actual Length Written  }
  239.         bufferPtr:                Ptr;                                    {  52 -->   Pointer to message buffer  }
  240.         more:                    BOOLEAN;                                {  56 -->   if more data in this block will be written  }
  241.         filler2:                SInt8;
  242.         userData:                UInt32;                                    {  58 -->   Message block userData Uninterpreted by PPC  }
  243.         blockCreator:            OSType;                                    {  62 -->   Message block creator Uninterpreted by PPC  }
  244.         blockType:                OSType;                                    {  66 -->   Message block type Uninterpreted by PPC  }
  245.     END;
  246.  
  247.     PPCWritePBPtr                        = ^PPCWritePBRec;
  248.     PPCReadPBRecPtr = ^PPCReadPBRec;
  249.     PPCReadPBRec = RECORD
  250.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  251.         csCode:                    UInt16;                                    {  Requested PPC command  }
  252.         intUse:                    UInt16;                                    {  Internal Use  }
  253.         intUsePtr:                Ptr;                                    {  Internal Use  }
  254.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  255.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  256.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  257.         filler1:                INTEGER;
  258.         sessRefNum:                PPCSessRefNum;                            {  40 -->   Session Reference  }
  259.         bufferLength:            Size;                                    {  44 -->   Length of the message buffer  }
  260.         actualLength:            Size;                                    {  48 <--   Actual length read  }
  261.         bufferPtr:                Ptr;                                    {  52 -->   Pointer to message buffer  }
  262.         more:                    BOOLEAN;                                {  56 <--   if true more data in this block to be read  }
  263.         filler2:                SInt8;
  264.         userData:                UInt32;                                    {  58 <--   Message block userData Uninterpreted by PPC  }
  265.         blockCreator:            OSType;                                    {  62 <--   Message block creator Uninterpreted by PPC  }
  266.         blockType:                OSType;                                    {  66 <--   Message block type Uninterpreted by PPC  }
  267.     END;
  268.  
  269.     PPCReadPBPtr                        = ^PPCReadPBRec;
  270.     PPCEndPBRecPtr = ^PPCEndPBRec;
  271.     PPCEndPBRec = RECORD
  272.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  273.         csCode:                    UInt16;                                    {  Requested PPC command  }
  274.         intUse:                    UInt16;                                    {  Internal Use  }
  275.         intUsePtr:                Ptr;                                    {  Internal Use  }
  276.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  277.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  278.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  279.         filler1:                INTEGER;
  280.         sessRefNum:                PPCSessRefNum;                            {  40 -->   Session Reference  }
  281.     END;
  282.  
  283.     PPCEndPBPtr                            = ^PPCEndPBRec;
  284.     PPCClosePBRecPtr = ^PPCClosePBRec;
  285.     PPCClosePBRec = RECORD
  286.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  287.         csCode:                    UInt16;                                    {  Requested PPC command  }
  288.         intUse:                    UInt16;                                    {  Internal Use  }
  289.         intUsePtr:                Ptr;                                    {  Internal Use  }
  290.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  291.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  292.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  293.         portRefNum:                PPCPortRefNum;                            {  38 -->   Port Identifier  }
  294.     END;
  295.  
  296.     PPCClosePBPtr                        = ^PPCClosePBRec;
  297.     IPCListPortsPBRecPtr = ^IPCListPortsPBRec;
  298.     IPCListPortsPBRec = RECORD
  299.         qLink:                    Ptr;                                    {  PPC's Internal Use  }
  300.         csCode:                    UInt16;                                    {  Requested PPC command  }
  301.         intUse:                    UInt16;                                    {  Internal Use  }
  302.         intUsePtr:                Ptr;                                    {  Internal Use  }
  303.         ioCompletion:            PPCCompUPP;                                {  12 -->    Completion Routine  }
  304.         ioResult:                OSErr;                                    {  16 <--     Command Result Code  }
  305.         Reserved:                ARRAY [0..4] OF UInt32;                    {  Reserved for PPC, Don't use  }
  306.         filler1:                INTEGER;
  307.         startIndex:                UInt16;                                    {  40 -->   Start Index  }
  308.         requestCount:            UInt16;                                    {  42 -->   Number of entries to be returned  }
  309.         actualCount:            UInt16;                                    {  44 <--   Actual Number of entries to be returned  }
  310.         portName:                PPCPortPtr;                                {  46 -->   PortName Match  }
  311.         locationName:            LocationNamePtr;                        {  50 -->   NBP or NAS type name to locate the Port Location  }
  312.         bufferPtr:                PortInfoArrayPtr;                        {  54 -->   Pointer to a buffer requestCount*sizeof(PortInfo) bytes big  }
  313.     END;
  314.  
  315.     IPCListPortsPBPtr                    = ^IPCListPortsPBRec;
  316.     PPCParamBlockRec = RECORD
  317.         CASE INTEGER OF
  318.         0: (
  319.             openParam:            PPCOpenPBRec;
  320.             );
  321.         1: (
  322.             informParam:        PPCInformPBRec;
  323.             );
  324.         2: (
  325.             startParam:            PPCStartPBRec;
  326.             );
  327.         3: (
  328.             acceptParam:        PPCAcceptPBRec;
  329.             );
  330.         4: (
  331.             rejectParam:        PPCRejectPBRec;
  332.             );
  333.         5: (
  334.             writeParam:            PPCWritePBRec;
  335.             );
  336.         6: (
  337.             readParam:            PPCReadPBRec;
  338.             );
  339.         7: (
  340.             endParam:            PPCEndPBRec;
  341.             );
  342.         8: (
  343.             closeParam:            PPCClosePBRec;
  344.             );
  345.         9: (
  346.             listPortsParam:        IPCListPortsPBRec;
  347.             );
  348.     END;
  349.  
  350. {  PPC Calling Conventions  }
  351. FUNCTION PPCInit: OSErr;
  352.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  353.     INLINE $7000, $A0DD, $3E80;
  354.     {$ENDC}
  355.  
  356. FUNCTION PPCOpenSync(pb: PPCOpenPBPtr): OSErr;
  357.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  358.     INLINE $205F, $7001, $A0DD, $3E80;
  359.     {$ENDC}
  360. FUNCTION PPCOpenAsync(pb: PPCOpenPBPtr): OSErr;
  361.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  362.     INLINE $205F, $7001, $A4DD, $3E80;
  363.     {$ENDC}
  364. FUNCTION PPCInformSync(pb: PPCInformPBPtr): OSErr;
  365.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  366.     INLINE $205F, $7003, $A0DD, $3E80;
  367.     {$ENDC}
  368. FUNCTION PPCInformAsync(pb: PPCInformPBPtr): OSErr;
  369.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  370.     INLINE $205F, $7003, $A4DD, $3E80;
  371.     {$ENDC}
  372. FUNCTION PPCStartSync(pb: PPCStartPBPtr): OSErr;
  373.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  374.     INLINE $205F, $7002, $A0DD, $3E80;
  375.     {$ENDC}
  376. FUNCTION PPCStartAsync(pb: PPCStartPBPtr): OSErr;
  377.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  378.     INLINE $205F, $7002, $A4DD, $3E80;
  379.     {$ENDC}
  380. FUNCTION PPCAcceptSync(pb: PPCAcceptPBPtr): OSErr;
  381.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  382.     INLINE $205F, $7004, $A0DD, $3E80;
  383.     {$ENDC}
  384. FUNCTION PPCAcceptAsync(pb: PPCAcceptPBPtr): OSErr;
  385.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  386.     INLINE $205F, $7004, $A4DD, $3E80;
  387.     {$ENDC}
  388. FUNCTION PPCRejectSync(pb: PPCRejectPBPtr): OSErr;
  389.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  390.     INLINE $205F, $7005, $A0DD, $3E80;
  391.     {$ENDC}
  392. FUNCTION PPCRejectAsync(pb: PPCRejectPBPtr): OSErr;
  393.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  394.     INLINE $205F, $7005, $A4DD, $3E80;
  395.     {$ENDC}
  396. FUNCTION PPCWriteSync(pb: PPCWritePBPtr): OSErr;
  397.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  398.     INLINE $205F, $7006, $A0DD, $3E80;
  399.     {$ENDC}
  400. FUNCTION PPCWriteAsync(pb: PPCWritePBPtr): OSErr;
  401.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  402.     INLINE $205F, $7006, $A4DD, $3E80;
  403.     {$ENDC}
  404. FUNCTION PPCReadSync(pb: PPCReadPBPtr): OSErr;
  405.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  406.     INLINE $205F, $7007, $A0DD, $3E80;
  407.     {$ENDC}
  408. FUNCTION PPCReadAsync(pb: PPCReadPBPtr): OSErr;
  409.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  410.     INLINE $205F, $7007, $A4DD, $3E80;
  411.     {$ENDC}
  412. FUNCTION PPCEndSync(pb: PPCEndPBPtr): OSErr;
  413.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  414.     INLINE $205F, $7008, $A0DD, $3E80;
  415.     {$ENDC}
  416. FUNCTION PPCEndAsync(pb: PPCEndPBPtr): OSErr;
  417.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  418.     INLINE $205F, $7008, $A4DD, $3E80;
  419.     {$ENDC}
  420. FUNCTION PPCCloseSync(pb: PPCClosePBPtr): OSErr;
  421.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  422.     INLINE $205F, $7009, $A0DD, $3E80;
  423.     {$ENDC}
  424. FUNCTION PPCCloseAsync(pb: PPCClosePBPtr): OSErr;
  425.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  426.     INLINE $205F, $7009, $A4DD, $3E80;
  427.     {$ENDC}
  428. FUNCTION IPCListPortsSync(pb: IPCListPortsPBPtr): OSErr;
  429.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  430.     INLINE $205F, $700A, $A0DD, $3E80;
  431.     {$ENDC}
  432. FUNCTION IPCListPortsAsync(pb: IPCListPortsPBPtr): OSErr;
  433.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  434.     INLINE $205F, $700A, $A4DD, $3E80;
  435.     {$ENDC}
  436. FUNCTION DeleteUserIdentity(userRef: UInt32): OSErr;
  437. FUNCTION GetDefaultUser(VAR userRef: UInt32; VAR userName: Str32): OSErr;
  438. FUNCTION StartSecureSession(pb: PPCStartPBPtr; VAR userName: Str32; useDefault: BOOLEAN; allowGuest: BOOLEAN; VAR guestSelected: BOOLEAN; prompt: Str255): OSErr;
  439.  
  440. TYPE
  441. {$IFC TYPED_FUNCTION_POINTERS}
  442.     PPCFilterProcPtr = FUNCTION(name: LocationNamePtr; port: PortInfoPtr): BOOLEAN;
  443. {$ELSEC}
  444.     PPCFilterProcPtr = ProcPtr;
  445. {$ENDC}
  446.  
  447.     PPCFilterUPP = UniversalProcPtr;
  448.  
  449. CONST
  450.     uppPPCCompProcInfo = $000000C0;
  451.     uppPPCFilterProcInfo = $000003D0;
  452.  
  453. FUNCTION NewPPCCompProc(userRoutine: PPCCompProcPtr): PPCCompUPP;
  454.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  455.     INLINE $2E9F;
  456.     {$ENDC}
  457.  
  458. FUNCTION NewPPCFilterProc(userRoutine: PPCFilterProcPtr): PPCFilterUPP;
  459.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  460.     INLINE $2E9F;
  461.     {$ENDC}
  462.  
  463. PROCEDURE CallPPCCompProc(pb: PPCParamBlockPtr; userRoutine: PPCCompUPP);
  464.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  465.     INLINE $205F, $4E90;
  466.     {$ENDC}
  467.  
  468. FUNCTION CallPPCFilterProc(name: LocationNamePtr; port: PortInfoPtr; userRoutine: PPCFilterUPP): BOOLEAN;
  469.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  470.     INLINE $205F, $4E90;
  471.     {$ENDC}
  472. FUNCTION PPCBrowser(prompt: Str255; applListLabel: Str255; defaultSpecified: BOOLEAN; VAR theLocation: LocationNameRec; VAR thePortInfo: PortInfoRec; portFilter: PPCFilterUPP; theLocNBPType: Str32): OSErr;
  473.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  474.     INLINE $303C, $0D00, $A82B;
  475.     {$ENDC}
  476.  
  477. {
  478.   The ParamBlock calls with the "Sync" or "Async" suffix are being phased out.
  479. }
  480. FUNCTION PPCOpen(pb: PPCOpenPBPtr; async: BOOLEAN): OSErr;
  481. FUNCTION PPCInform(pb: PPCInformPBPtr; async: BOOLEAN): OSErr;
  482. FUNCTION PPCStart(pb: PPCStartPBPtr; async: BOOLEAN): OSErr;
  483. FUNCTION PPCAccept(pb: PPCAcceptPBPtr; async: BOOLEAN): OSErr;
  484. FUNCTION PPCReject(pb: PPCRejectPBPtr; async: BOOLEAN): OSErr;
  485. FUNCTION PPCWrite(pb: PPCWritePBPtr; async: BOOLEAN): OSErr;
  486. FUNCTION PPCRead(pb: PPCReadPBPtr; async: BOOLEAN): OSErr;
  487. FUNCTION PPCEnd(pb: PPCEndPBPtr; async: BOOLEAN): OSErr;
  488. FUNCTION PPCClose(pb: PPCClosePBPtr; async: BOOLEAN): OSErr;
  489. FUNCTION IPCListPorts(pb: IPCListPortsPBPtr; async: BOOLEAN): OSErr;
  490.  
  491.  
  492. {$ALIGN RESET}
  493. {$POP}
  494.  
  495. {$SETC UsingIncludes := PPCToolboxIncludes}
  496.  
  497. {$ENDC} {__PPCTOOLBOX__}
  498.  
  499. {$IFC NOT UsingIncludes}
  500.  END.
  501. {$ENDC}
  502.